package com.hrzyit.whistle.comm.service.impl

import com.hrzyit.base.ext.convert
import com.hrzyit.whistle.comm.data.bean.DepartmentEntity
import com.hrzyit.whistle.comm.data.repository.ContactCenterRepository
import com.hrzyit.whistle.comm.service.IDepartmentService
import io.reactivex.Observable
import javax.inject.Inject

/**
 * 联络单位 Service 接口实现类
 * @author YangWei
 * @date 2019/5/6
 */
class DepartmentServiceImpl @Inject constructor() : IDepartmentService {

    @Inject
    lateinit var contactCenterRepository: ContactCenterRepository

    override fun selectContactDeptList(userId:Long): Observable<MutableList<DepartmentEntity>> {
        return contactCenterRepository.selectContactDeptList(userId).convert()
    }
}